import request from '@/router/axios';

export const getList = (page, size, params) => {
    return request({
        url: '/account/withDrawRecord/listUsedAdmin',
        method: 'post',
        params: {
            ...params,
            page,
            size,
        }
    })
}


export const getWithDrawRecordDetail = id => {
    return request({
        url: '/account/withDrawRecord/detail',
        method: "post",
        meta: {
            isSerialize: true,
        },
        data: {
            id
        }
    });
};


export const withDrawStatusOthers = (id,status,refuseRemark) => {
    return request({
        url: '/account/withDrawRecord/withDrawStatusOthers',
        method: "post",
        meta: {
            isSerialize: true,
        },
        data: {
            id,
            status,
            refuseRemark
        }
    });
};

//用户提交打款操作
export const withDrawCarryOut = (id,payStatus,actualAmount,payRemark) => {
    return request({
        url: '/account/withDrawRecord/withDrawCarryOut',
        method: "post",
        meta: {
            isSerialize: true,
        },
        data: {
            id,
            payStatus,
            actualAmount,
            payRemark
        }
    });
};

export const selectAndUpdate = (data) => {
    return request({
        url: '/account/withDrawRecord/selectAndUpdate',
        method: 'post',
        meta: {
            isSerialize: true,
        },
        data:data
    });
};


